﻿/**
 *	@auth    Chunning.Xu
 *	@purpose manage all tracking server
 *	@date 	 2008-11-25
 *
 */
package com.components.net.tracking
{
	import com.components.net.tracking.TrackingServer.GoogleAnalyze;
	import com.components.net.tracking.TrackingServer.I_TrackingServer;
	import com.components.net.tracking.TrackingServer.Migo;
	
	
	public class TrackingServerManagement
	{
		//START
	
		//property
		
		private static var google:I_TrackingServer = new GoogleAnalyze;
		
		private static var migo:I_TrackingServer = new Migo;
		
		public static var trackingServers:Array = [];
				
		//CONSTRUCTOR
		public function TrackingServerManagement()
		{
			
		}
		
		//methods
		static public function sendData(track:TrackingData):void
		{
			
			var trackingServer:I_TrackingServer;
			
			for(var i:uint = 0;i < trackingServers.length;i++)
			{
				
				trackingServer = trackingServers[i] as I_TrackingServer;
				
				trackingServer.sendData(track);
				
			}
			
		}
		
		
		//END
	}
}